﻿<%@ Page Language="C#" AutoEventWireup="true" CodeBehind="txtAjaxt.aspx.cs" Inherits="HQWeb.View.txtAjaxt" %>

<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head runat="server">
    <linktitle></linktitle>
    <style type="text/css">
        .linktitle
        {
            padding: 4px;
            font-size: 14px;
        }
        .linktitle img
        {
            width: 14px;
            height: 14px;
            float: right;
            cursor: pointer;
        }
        .linkwindow
        {
            width: 500px; /*padding: 2px;*/
            margin: 5px; /*控制窗口绝对定位*/
            position: absolute;
             border: 2px solid #D0DEF0;
             display: none;
        }
   
        .linct_content
        {
            height: 250px;
           
            padding: 2px; /*控制区域内容超过指定高度和宽度时显示滚动条*/
            overflow: auto;
        }
        .g_clr
        {
            width: 400px;
        }
        .g_clr span
        {
            display: inline-block;
            height: 30px;
            line-height: 30px;
            width: 116px;
        }
        .js_text
        {
            color: #000000;
            overflow: hidden;
            text-decoration: none;
            text-overflow: ellipsis;
            white-space: nowrap;
            width: 64px;
        }
        .js_psite-sites li
        {
            background-color: #FFFFFF;
            border: 1px dotted #BBBBBB;
            display: inline;
            float: left;
            font-size: 14px;
            height: 20px;
            line-height: 20px;
            margin: 4px 0 4px 8px;
            overflow: hidden;
            width: 107px;
        }
        .js_modify
        {
            float: left;
            margin-left: 5px;
            background-image: url("http://s0.hao123img.com/index/images/site/sprite0829.png");
            background-repeat: no-repeat;
            height: 20px;
            background-position: -88px 4px;
            width: 9px;
        }
        .js_delete
        {
            float: left;
            margin-left: 5px;
            background-image: url("http://s0.hao123img.com/index/images/site/sprite0829.png");
            background-repeat: no-repeat;
            height: 20px;
            background-position: -60px 4px;
            width: 15px;
        }
        .js_psite-sites {
     overflow: hidden;
    padding: 12px 0 12px 8px;
    position: relative;
  
}
    </style>
    <script type="text/javascript" src="../Scripts/jquery-1.7.2.js"></script>
    <script type="text/javascript" language="javascript">
        $(document).ready(function () {
            //            var width = document.body.offsetWidth;
            //            var varTemp = (width - 1216) / 2;

            //            var height = $(linkwindow).outerHeight(true);

            //            $(".addPage").css("left", varTemp - 20);

            //            $(".addPage").css("top", height / 2);

            //            $(".addPage").css("position", "fixed");

            //            $(".addPage").css("position", "pointer");

            //            $(".addPage").css("width", "40");
            //            $(".addPage").css("height", "60");
           // $(".linktitle").width();
            $(".linktitle").click(function () { $(".linkwindow").slideUp(); });
            //   $(".js_modify").click(function () { alert("123"); });
            //            $(".js_modify").click();
        });
        function funtxt() {
            var varstring = "id|21,ids|3";
            var str = varstring.split(",");
            var varTempArry;
            for (var i = 0; i < str.length; i++) {
                varTempArry = str[i].split("|");
                alert(varTempArry[0] + "数量：" + varTempArry[1]);
            }
        }
        function funtxt1() {
            var varstring = "btnProject";
            var str = varstring.substring(3);
            alert(str);
        }
        function funtxt2() {
            var varstring = "027c5d80-88d3-45b7-8f3f-42cfbb10221d|1,13eef2b1-70b0-47d7-b205-018fecf379c6|2,22c8920e-8b22-4b8e-889d-2ec298f23ed9|3,";
            var start = varstring.indexOf("22c8920e-8b22-4b8e-889d-2ec298f23ed9|");
            var end = varstring.indexOf(",", start);
            var str;
            if (end != -1) {
                str = varstring.substring(start, end + 1);
            } else {
                str = varstring.substring(start);
            }

            alert(str);
        }
        function funtxt3() {
            var tdid = "#trafe7d8a9-17f3-4d4a-98fd-844b011b44f3";
            // var NumberValue = 200;
            $(tdid).remove();
            // $("#trid").children("td").eq(1).html("200");
        }
        function checkIsInt(obj) {
            var value = obj.value.replace(/\s+/g, "");

            if (value == "") {
                alert("bu neng wei kong ");
            }
            if (isNaN(value)) {
                alert("false");
            }
        }

        function funtxt4() {
            var sum = 0;
            var temp;
            var tempValue;
            $("#ShopConnect tr").each(function (index) {
                temp = $(this).children("td");
                tempValue = parseFloat(temp.eq(2).html(), 10) * parseFloat(temp.eq(3).html());
                if (!isNaN(tempValue)) {
                    sum = sum + tempValue;
                }
            });
            alert(sum);
        }
        function funtxt5(inputid) {
            //   alert($("#" + inputid).attr("dataid"));
            var withs = $("#" + inputid).offset().left;
            var hights = $("#" + inputid).offset().top;
            $.ajax({
                type: "GET",
                url: "GetLink.ashx?type=editview",
                success: function (obj) {
                    if (obj != "") {
                        $(".linct_content").html(obj);
                        $(".linkwindow").css("left", withs);
                        $(".linkwindow").css("top", hights);
                        $(".linkwindow").show();
                    }

                },
                error: function (xhr, ajaxOptions, thrownError)
                { alert(thrownError); flag = true; return false; }
            });
        }
       
    </script>
</head>
<body>
    <form id="form1" runat="server">
    <asp:Button runat="server" ID="tt" Text="ce shi" OnClick="tt_Click" />
    <input type="button" id="cf" value="ccffff" onclick="funtxt4()" />
    <div>
        <a id="aclick" onclick="funtxt5('aclick')" dataid="1">显示</a>
    </div>
    <div>
        <asp:GridView ID="GridView1" runat="server">
        </asp:GridView>
    </div>
    <div class="addPage" style="z-index=20; background-color: Black" onclick="javascript:alert('f');">
        <image src="../../Images/View/m1.png" onclick="javascript:alert(ff);"></image>
    </div>
    <div class="linkwindow">
        <div class="linktitle">
            <img alt="关闭" src="../Images/View/close.gif" />
        </div>
        <div class="linct_content">
            <div>
                <ul class="js_psite-sites">
                    <li data-url="1234" class="js_site-item"><span class="js_text">123</span><a hidefocus="true"
                        linktitle="修改" href="#" class="js_modify"></a><a hidefocus="true" linktitle="删除"
                            href="#" class="js_delete"></a></li><li data-url="2" class="js_site-item"><span class="js_text">
                                2</span><a hidefocus="true" linktitle="修改" href="#" class="js_modify"></a><a hidefocus="true"
                                    linktitle="删除" href="#" class="js_delete"></a></li>
                </ul>
            </div>
            <div style="clear: both">
                网站名称：<input class="js_sug-name name" id="js_sug-name" autocomplete="off" />网址:<input
                    class="js_sug-url url" id="js_sug-url" autocomplete="off" />
                <input type="button" value="保存" onclick="funSaveLink('add')" />
            </div>
        </div>
    </div>
    <%--  <div class="g_clr">
        <span><a href="http://www.renren.com/">人 人 网</a></span><span><a href="http://v.hao123.com/">影视排行榜</a></span><span><a
            href="http://www.iqiyi.com/zongyi/zghsy.html">中国好声音</a></span><span><a href="http://www.autohome.com.cn">汽车之家</a></span><span><a
                href="http://www.qunar.com/">去哪儿网</a></span><span><a class="g_red" href="http://www.12306.cn">12306火车票</a></span><span><a
                    href="http://www.eastmoney.com">东方财富</a></span><span><a href="http://www.58.com">58
                        同 城</a></span><span><a href="http://www.zhcw.com">中 彩 网</a></span><span><a class="widget-links-l em"
                            href="http://www.xinhuanet.com">新华</a>•<a class="widget-links-r" href="http://www.people.com.cn/">人民</a></span><span><a
                                href="http://www.mogujie.com">蘑 菇 街</a></span><span><a href="http://www.zhaopin.com/">智联招聘</a></span><span><a
                                    href="http://www.icbc.com.cn/">工商银行</a></span><span><a href="http://www.vancl.com/?source=hao123mph">凡客诚品</a></span><span><a
                                        href="http://www.zol.com.cn/">中关村在线</a></span><span><a href="http://www.gome.com.cn/ec/homeus/?cmpid=dh_hao123_mz">国美电器</a></span><span><a
                                            href="http://www.bitauto.com/">易 车 网</a></span><span><a href="http://www.yihaodian.com?tracker_u=10861423206">1
                                                号 店</a></span><span><a href="http://www.qiushibaike.com/">糗事百科</a></span><span><a
                                                    href="http://www.zhenai.com/">珍 爱 网</a></span><span><a href="http://www.ganji.com">赶
                                                        集 网</a></span><span><a href="http://aola.100bt.com/">奥 拉 星</a></span><span><a href="http://www.google.com.hk/">谷&#12288;歌</a></span><span><a
                                                            href="http://xiangce.baidu.com/index.html">百度相册</a></span><span><a class="tc-green"
                                                                href="http://click.union.360buy.com/JdClick/?unionId=75">京东商城</a></span><span><a
                                                                    class="tc-green" href="http://www.suning.com/">苏宁易购</a></span><span><a class="tc-green"
                                                                        href="http://r.dangdang.com/hao123mingzhan">当 当 网</a></span><span><a class="tc-green"
                                                                            href="http://www.amazon.cn/?tag=hao123com-famous-23">卓越亚马逊</a></span><span><a class="tc-green"
                                                                                href="http://www.jumei.com?referer=hao123_mz">聚美优品</a></span><span><a class="tc-green"
                                                                                    href="http://reg.jiayuan.com/st/?id=3237&amp;url=/st/main.php">世纪佳缘</a></span></div>--%>
    <%--    <div class="popup-site-self">
        <ul class="js_psite-sites">
            <li data-url="http://www.baidu.com/" data-name="百度" data-id="66523" class="js_site-item"
                style="left: 16px; top: 16px;"><span class="js_text">百&#12288;度</span><a hidefocus="true"
                    linktitle="修改" href="#" class="js_modify"></a><a hidefocus="true" linktitle="删除" href="#"
                        class="js_delete"></a></li>
            <li data-url="http://www.sina.com.cn/" data-name="新浪" data-id="66524" class="js_site-item"
                linktitle="拖动排序"><span class="js_text">新&#12288;浪</span><a hidefocus="true" linktitle="修改"
                    href="#" class="js_modify"></a><a hidefocus="true" linktitle="删除" href="#" class="js_delete"></a></li></ul>
        <div style="display: none" class="js_nodata-hint popup-site-nodata-hint">
            没有常用网址，请您在下面添加</div>
   
    </div>--%>
    <input type="text" value="add" id="Linksign" />
    <input type="text" value="" id="linkid" />
    <input type="button" value="保存" onclick="showEdit()" />
    </form>
</body>
</html>
